package demos;

import demos.beans.Classes;
import demos.mapper.ClassesMapper;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.support.ClassPathXmlApplicationContext;
@ComponentScan
public class App {


    public static void main(String[] args) {
        ClassPathXmlApplicationContext applicationContext =
                new ClassPathXmlApplicationContext("classpath:spring.xml");
        ClassesMapper bean = applicationContext.getBean(ClassesMapper.class);
        Classes classes = bean.selectByPrimaryKey(1);
        System.out.println(classes);
    }
}
